package cn.com.dycc.sys_manage.usersysmanagement.entity;


import java.io.Serializable;
import java.sql.Timestamp;

import com.fasterxml.jackson.annotation.JsonFormat;

public class UserChildAccount implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 8658655617526434287L;
	
	private String id;			//子表序号
	private String user_id;		//主表id
	private String account;		//账户
	private String principal;	//默认账户
//	private String usable;
	private String class_no;	//职务
	private String post_no;		//岗位
	private String dept_no;		//所属部门
	private String top_dept_no;	//所属单位
	private String state;		//是否启用
	private String org_id;			//使用组织ID
	private Timestamp create_date;	//创建时间
	private String opt_user_id;		//创建人
	private String update_date;		//记录修改时间
	private String update_user_id;	//记录修改的员工编号
	
	public UserChildAccount(){}

	public UserChildAccount(String id, String user_id, String account, String principal, String class_no,
			String post_no, String dept_no, String top_dept_no, String state, String org_id, Timestamp create_date,
			String opt_user_id, String update_date, String update_user_id) {
		super();
		this.id = id;
		this.user_id = user_id;
		this.account = account;
		this.principal = principal;
		this.class_no = class_no;
		this.post_no = post_no;
		this.dept_no = dept_no;
		this.top_dept_no = top_dept_no;
		this.state = state;
		this.org_id = org_id;
		this.create_date = create_date;
		this.opt_user_id = opt_user_id;
		this.update_date = update_date;
		this.update_user_id = update_user_id;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getUser_id() {
		return user_id;
	}

	public void setUser_id(String user_id) {
		this.user_id = user_id;
	}

	public String getAccount() {
		return account;
	}

	public void setAccount(String account) {
		this.account = account;
	}

	public String getPrincipal() {
		return principal;
	}

	public void setPrincipal(String principal) {
		this.principal = principal;
	}

	public String getClass_no() {
		return class_no;
	}

	public void setClass_no(String class_no) {
		this.class_no = class_no;
	}

	public String getPost_no() {
		return post_no;
	}

	public void setPost_no(String post_no) {
		this.post_no = post_no;
	}

	public String getDept_no() {
		return dept_no;
	}

	public void setDept_no(String dept_no) {
		this.dept_no = dept_no;
	}

	public String getTop_dept_no() {
		return top_dept_no;
	}

	public void setTop_dept_no(String top_dept_no) {
		this.top_dept_no = top_dept_no;
	}

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	public String getOrg_id() {
		return org_id;
	}

	public void setOrg_id(String org_id) {
		this.org_id = org_id;
	}

	public Timestamp getCreate_date() {
		return create_date;
	}

	public void setCreate_date(Timestamp create_date) {
		this.create_date = create_date;
	}

	public String getOpt_user_id() {
		return opt_user_id;
	}

	public void setOpt_user_id(String opt_user_id) {
		this.opt_user_id = opt_user_id;
	}
	
	@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
	public String getUpdate_date() {
		return update_date;
	}
	
	public void setUpdate_date(String update_date) {
		this.update_date = update_date;
	}

	public String getUpdate_user_id() {
		return update_user_id;
	}

	public void setUpdate_user_id(String update_user_id) {
		this.update_user_id = update_user_id;
	}

	@Override
	public String toString() {
		return "UserChildAccount [id=" + id + ", user_id=" + user_id + ", account=" + account + ", principal="
				+ principal + ", class_no=" + class_no + ", post_no=" + post_no + ", dept_no=" + dept_no
				+ ", top_dept_no=" + top_dept_no + ", state=" + state + ", org_id=" + org_id + ", create_date="
				+ create_date + ", opt_user_id=" + opt_user_id + ", update_date=" + update_date + ", update_user_id="
				+ update_user_id + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((id == null) ? 0 : id.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		UserChildAccount other = (UserChildAccount) obj;
		if (id == null) {
			if (other.id != null)
				return false;
		} else if (!id.equals(other.id))
			return false;
		return true;
	}

	
}

